Imaging device for distinguishing foreground and operating method thereof, and image sensor

ABSTRACT

An imaging device including a condenser lens and an image sensor is provided. The image sensor is configured to sense light penetrating the condenser lens and includes a pixel matrix, an opaque layer, a plurality of microlenses and an infrared filter layer. The pixel matrix includes a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels. The opaque layer covers upon a first region of the first pixels and a second region of the second pixels, wherein the first region and the second region are mirror- symmetrically arranged in a first direction. The plurality of microlenses is arranged upon the pixel matrix. The infrared filter layer covers upon the infrared pixels.

RELATED APPLICATIONS

The present application is based on and claims priority to Taiwanese Application Number 104129150, filed Sep. 02, 2015, the disclosure of which is hereby incorporated by reference herein in its entirety.

BACKGROUND

1. Field of the Disclosure

This disclosure generally relates to an optical image sensor and, more particularly, to an imaging device capable of distinguishing foreground and background and an operating method thereof.

2. Description of the Related Art

Activating a predetermined application of a system by recognizing gestures has been broadly applied to various electronic devices, e.g., portable electronic devices or wearable electronic devices. A conventional method for distinguishing foreground and background adopts a system light source to illuminate the object located within an operating range. When the system light source is illuminating light, an image sensor captures a bright image; whereas, when the system light source does not illuminate light, the image sensor captures a dark image. By calculating a differential image between the bright image and the dark image, it is able to cancel the interference from background.

However, the portable electronic device and the wearable electronic device are generally operated under strong light, e.g., under sunlight. As the brightness of the system light source is very weak compared to sunlight, the background interference can not be effectively cancelled by only calculating the differential image between bright and dark images.

Accordingly, an imaging device without being limited by ambient light intensity is required in the art.

SUMMARY

The present disclosure provides an imaging device capable of distinguishing foreground and an operating method thereof that incorporate the phase detection to overcome the limitation caused by strong ambient light.

The present disclosure further provides an imaging device capable of distinguishing foreground and an operating method thereof that operate in different operating modes under different ambient light intensity.

The present disclosure provides an imaging device including a condenser lens and an image sensor. The image sensor is configured to sense light penetrating the condenser lens and includes a pixel matrix, an opaque layer, a plurality of microlenses and an infrared filter layer. The pixel matrix includes a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels arranged in a first direction and a second direction. The opaque layer covers upon a first region of the first pixels and upon a second region of the second pixels, wherein the first region and the second region are mirror-symmetrically arranged in the first direction. The infrared filter layer covers upon the infrared pixels.

The present disclosure further provides an imaging device including an infrared light source, a condenser lens, an image sensor and a processor. The image sensor is configured to sense light penetrating the condenser lens, output a bright image frame when the infrared light source is turned on and output a dark image frame when the infrared light source is turned off. The image sensor includes a pixel matrix, an opaque layer, a plurality of microlenses and an infrared filter layer. The pixel matrix includes a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels arranged in a first direction and a second direction. The opaque layer covers upon a first region of the first pixels and upon a second region of the second pixels, wherein the first region and the second region are mirror-symmetrically arranged in the first direction. The microlenses are disposed upon the pixel matrix. The infrared filter layer covers upon the infrared pixels. The processor is configured to form an infrared subframe according to infrared image regions in the bright image frame and the dark image frame corresponding to the infrared pixels, form a first subframe according to first image regions in the bright image frame and the dark image frame corresponding to the first pixels, form a second subframe according to second image regions in the bright image frame and the dark image frame corresponding to the second pixels, and calculate, in a first mode, a differential image between the infrared subframe of the bright image frame and the infrared subframe of the dark image frame to separate at least one foreground image, or separate at least one foreground image according to the first subframe and the second subframe in a second mode.

The present disclosure further provides an operating method of an imaging device. The imaging device includes an infrared light source, a plurality of infrared pixels, a plurality of first pixels, a plurality of second pixels and a plurality of microlenses. The first pixels and the second pixels respectively receive incident light of different phases through a first part and a second part of the microlenses. The operating method includes the steps of: outputting, by the imaging device, a bright image frame when the infrared light source is turned on and a dark image frame when the infrared light source is turned off; forming an infrared subframe according to infrared image regions corresponding to the infrared pixels, forming a first subframe according to first image regions corresponding to the first pixels, and forming a second subframe according to second image regions corresponding to the second pixels; calculating, in a first mode, a differential image between the infrared subframe of the bright image frame and the infrared subframe of the dark image frame to separate at least one foreground image; and separating, in a second mode, at least one foreground image according to the first subframe and the second subframe.

The present disclosure further provides an image sensor including a pixel matrix, an opaque layer, a plurality of microlenses and an infrared filter layer. The pixel matrix includes a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels arranged in a first direction and a second direction. The opaque layer covers upon a first region of the first pixels and upon a second region of the second pixels, wherein the first region and the second region are mirror-symmetrically arranged in the first direction. The microlenses are disposed upon the pixel matrix. The infrared filter layer covers upon the infrared pixels.

BRIEF DESCRIPTION OF THE DRAWINGS

Other objects, advantages, and novel features of the present disclosure will become more apparent from the following detailed description when taken in conjunction with the accompanying drawings.

FIG. 1 is a schematic block diagram of an imaging device according to one embodiment of the present disclosure.

FIGS. 2A-2B are cross sectional views of an image sensor of an imaging device according to some embodiments of the present disclosure.

FIGS. 3A-3D are schematic diagrams of the arrangement of an opaque layer according to some embodiments of the present disclosure.

FIG. 4 is a schematic diagram of an operating method of an imaging device according to one embodiment of the present disclosure.

FIG. 5 is a schematic diagram of an operating method of a first mode of an imaging device according to one embodiment of the present disclosure.

FIG. 6 is a flow chart of an operating method of an imaging device according to one embodiment of the present disclosure.

DETAILED DESCRIPTION OF THE EMBODIMENT

It should be noted that, wherever possible, the same reference numbers will be used throughout the drawings to refer to the same or like parts.

Referring to FIGS. 1 and 2A-2B, FIG. 1 is a schematic block diagram of an imaging device according to one embodiment of the present disclosure; and FIGS. 2A-2B are cross sectional views of an image sensor of an imaging device according to some embodiments of the present disclosure. The imaging device 1 includes a condenser lens 10, an image sensor 11, a processor 13 and an infrared light source 15. In some embodiments, the processor 13 is disposed, for example, in a same chip together with the image sensor 11 and the infrared light source 15. In some embodiments, the processor 13 is, for example, an external processing unit outside the image sensor 11, and is configured to receive and process image frames F captured by the image sensor 11 so as to select a first mode (e.g., a normal mode) or a second mode (e.g., a strong light mode) to separate at least one foreground image from the background image. For example, when the imaging device 1 is applied to the gesture recognition, the at least one foreground image is, for example, a hand of a user or an object held by a user. The processor 13 is, for example, a microcontroller (MCU), a central processing unit (CPU), a digital signal processor (DSP) or the like for processing image frames F outputted by the image sensor 11.

The infrared light source 15 is, for example, a light emitting diode or a laser diode, and is configured to emit infrared light Ls to illuminate an operable range of the imaging device 1, wherein the operable range is determined, for example, by element parameters of the imaging device 1. When an object 9 enters the operable range, the object 9 reflects the infrared light Ls toward the image sensor 11 to generate reflected light beams Lrs. In some embodiments, the imaging device 1 includes at least one optical element (not shown) to homogenize the light emitted by the infrared light source 15.

The condenser lens 10 is, for example, arranged in a lens of an image capturing device (e.g., a camera), and is a single lens or a lens set arranged along an optical axis without particular limitations. For simplification, a single lens is shown herein. The condenser lens 10 is served as a lens window configured to condense the reflected light beams Lrs from the object 9 or ambient light La, and guide the reflected light beams Lrs and the ambient light La to the image sensor 11. A distance between the condenser lens 10 and the image sensor 11 is preferably equal to a first focal length of the condenser lens 10 (e.g., the focal length close to a side of the image sensor 11). It is appreciated that when the ambient light La exists, the reflected light beams Lrs also contains a part of ambient light reflected by the object 9.

The image sensor 11 (e.g., a pixel matrix being shown herein) senses, based on a predetermined focal length, light (e.g., reflected light beams Lrs and ambient light La) penetrating the condenser lens 10 and outputs an image frame F. For example, the image sensor 11 outputs a bright image frame when the infrared light source 15 is turned on, and outputs a dark image frame when the infrared light source 15 is turned off. The image sensor 11 includes a pixel matrix (e.g., a 9×9 pixel matrix being shown herein), an opaque layer 113, a plurality of microlenses 115 and an infrared filter layer 117 (e.g., referring to FIGS. 2A and 2B), wherein the opaque layer 113 is patterned to cover at least a part of a plurality of pixels included in the pixel matrix 111 such that uncovered regions of the pixels receive incident light of different phases through different parts of the microlenses 115. The predetermined focal length is referred to a second focal length formed by the condenser lens 10 and the microlens 115 together as well as at a light incident side of the condenser lens 10. In the present disclosure, the predetermined focal length is sometimes referred to a predetermined focal length of the condenser lens 10 or the image sensor 11.

It is noticed that when an object 9 is at the second focal length (e.g., the focal length away from the image sensor 11, i.e. the predetermined focal length) of the condenser lens 10 to reflect the infrared light Ls or ambient light La to the imaging device 1, the object image in the image frame F outputted by the image sensor 11 does not have a position offset in the subframe corresponding to pixels under different cover patterns; whereas, when the object 9 is not at the second focal length, the object image in the image frame F outputted by the image sensor 11 has a position offset toward different directions in the subframe corresponding to pixels under different cover patterns (illustrated by examples below). Accordingly, it is possible for the imaging device 1 to identify whether the object 9 is a foreground image within the operable range by identifying whether the position offset is within a predetermined range. In other words, the imaging device 1 of the present disclosure has an operable range, and the imaging in the image frame F of an object within the operable range is referred to a foreground image herein.

In one embodiment, the pixel matrix 111 includes a plurality of infrared pixels P_(inf), a plurality of first pixels P₁ and a plurality of second pixels P₂ arranged along a first direction (e.g., X direction) and a second direction (e.g., Y direction). It should be mentioned that in the present disclosure, the first pixels P₁ and the second pixels P₂ are referred to pixels with different regions covered by the opaque layer 113. For example, in a monochromatic image sensor, structures of the first pixels P₁ and the second pixels P₂ are identical, but only cover patterns of the opaque layer 113 thereupon are different (as shown in FIG. 1). For example, in a color image sensor, the first pixels P₁ and the second pixels P₂ respectively include red pixels (e.g., red filter layer being formed thereon), green pixels (e.g., green filter layer being formed thereon), blue pixels (e.g., blue filter layer being formed thereon) or pixels of other colors, and cover patterns of the opaque layer 113 upon the first pixels P₁ and the second pixels P₂ are different. The infrared pixels P_(inf) are covered by an infrared filter layer 117 but are not covered by the opaque layer 113.

The opaque layer 113 is, for example, formed by the metal layer served as electrical paths (e.g., at least one layer of M1 to M10 in the CMOS process), a black light blocking layer formed in addition to said metal layer or a combination thereof without particular limitations as long as the opaque layer 113 is able to block a part of incident light. In this embodiment, the opaque layer 113 covers upon a first region (e.g., the region filled with oblique lines) of the first pixels P₁ and upon a second region (e.g., the region filled with oblique lines) of the second pixels P₂. In FIG. 1, the first region is at a side of the pixel along the first direction (e.g., X direction), and the second region is at a side of the pixel along an inverse direction of the first direction. The first region of the first pixels 1 and the second region of the second pixels are mirror-symmetrically arranged in the first direction. In addition, The first pixels P₁ further include an uncovered region (e.g., blank region) outside the first region, and the second pixels P₂ further include an uncovered region (e.g., blank region) outside the second region, wherein the uncovered region of the first pixels P₁ and the uncovered region of the second pixels P₂ receive incident light of different phases through different parts of the microlenses 115 (as shown in FIG. 2A).

For example in FIG. 1, the first region of the first pixels P₁ is at an upper side of the first pixels P₁, and the second region of the second pixels P₂ is at a lower side of the second pixels P₂. It should be mentioned that although FIG. 1 shows that the first region and the second region are substantially 50% of an area of a single pixel, it is only intended to illustrate but not to limit the present disclosure. In other embodiments, the first region and the second region are 5% to 95% of an area of a single pixel without particular limitations.

The microlenses 115 are disposed upon the pixel matrix 111, and respectively aligned with one pixel. The opaque layer 113 and the infrared filter layer 117 are sandwiched between the pixel matrix 111 and the microlenses 115, wherein distances between the opaque layer 113 and the pixel matrix 111 and between the infrared filter layer 117 and the pixel matrix 111 may or may not be identical without particular limitations. Accordingly, the first pixels P₁ and the second pixels P₂ receive incident light of different phases respectively through a first part of the microlenses 115 (e.g., the lower part of the microlenses 115 in FIG. 1 and the right part of the microlenses 115 in FIG. 2A) and a second part of the microlenses 115 (e.g., the upper part of the microlenses 115 in FIG. 1 and the left part of the microlenses 115 in FIG. 2A). It should be mentioned that although FIG. 2A shows that uncovered regions of the first pixels P₁ and the second pixels P₂ are substantially a half of the microlenses 115, it is only intended to illustrate but not to limit the present disclosure. It is appreciated that light capable of penetrating the microlenses 115 to reach the uncovered regions is determined by the cover pattern of the opaque layer 113. In the present disclosure, the first part and the second part of the microlenses 115 are arranged as 5% to 95% of the microlenses 115 without particular limitations.

In FIG. 1, the pixel matrix 111 further includes a plurality of third pixels P₃ and a plurality of fourth pixels P₄ arranged along the second direction (e.g., Y direction). The opaque layer 113 further covers upon a third region (e.g., the region filled with oblique lines) of the third pixels P₃ and upon a fourth region (e.g., the region filled with oblique lines) of the fourth pixels P₄, wherein the third region is at a side of the pixel along the second direction (e.g., Y direction), and the fourth region is at a side of the pixel along an inverse direction of the second direction. For example in FIG. 1, the third region is at the left side of the third pixels P₃, and the fourth region is at the right side of the fourth pixels P₄, and the third region and the fourth region are mirror-symmetrically arranged in the second direction.

More specifically, the opaque layer 113 covers upon the pixel matrix 111, and includes a first cover pattern covering upon a first region of the first pixels P₁, a second cover pattern covering upon a second region of the second pixels P₂, a third cover pattern covering upon a third region of the third pixels P₃, and a fourth cover pattern covering upon a fourth region of the fourth pixels P₄, wherein the first region and the second region are mirror-symmetrically arranged in a first direction, and the third region and the fourth region are mirror-symmetrically arranged in a second direction. In one embodiment, the first direction is perpendicular to the second direction. It should be mentioned that the arrangement of the first pixels P₁ to the fourth pixels P₄ is not limited to that shown in FIG. 1, and preferable the first pixels P₁ to the fourth pixels P₄ are uniformly arranged everywhere in the pixel matrix 111. In addition, in some embodiments the pixel matrix 111 includes only the first pixels P₁ and the second pixels P₂, or includes only the third pixels P₃ and the fourth pixels P₄ according to different applications.

In one embodiment, all of the first region, the second region, the third region and the fourth region of the pixel matrix 111 have identical areas (as shown in FIG. 1), e.g., 5% to 95% of an area of a single pixel.

It should be mentioned that although FIG. 1 shows that the first region and the second region are rectangles mirror symmetrical in a first direction, and the third region and the fourth region are rectangles mirror symmetrical in a second direction, it is only intended to illustrate but not to limit the present disclosure. In other embodiments, the first region to the fourth region are not rectangles. For example referring to FIGS. 3A to 3D, the uncovered regions (e.g., the blank region) of the first region to the fourth region are arranged to increase or monotonically increase along a predetermined direction (e.g., a direction in which two pixels adjacent to each other), and shapes thereof are mirror-symmetrical in the predetermined direction. When the first pixels P₁ (or the third pixels P₃) and the second pixels P₂ (or the fourth pixels P₄) are receiving incident light, as the phase difference between the received incident lights close to the center of the first pixels P₁ (or the third pixels P₃) and close to the center of the second pixels P₂ (or the fourth pixels P₄) is not obvious, whereas the phase difference between the received incident lights close to the edge of the first pixels P₁ (or the third pixels P₃) and close to the edge of the second pixels P₂ (or the fourth pixels P₄) is more obvious, the uncovered region close to the pixel edge is arranged to be larger than the uncovered region close to the pixel center so as to improve the accuracy of the phase detection. It should be mentioned that FIGS. 3A-3D are only intended to illustrate but not to limit the present disclosure.

The processor 13 is configured to form an infrared subframe F_(inf) according to infrared image regions I_(inf) in the bright image frame and the dark image frame corresponding to the infrared pixels P_(inf), form a first subframe F_(P1) according to first image regions I_(P1) in the bright image frame and the dark image frame corresponding to the first pixels P₁ and form a second subframe F_(P2) according to second image regions I_(P2) in the bright image frame and the dark image frame corresponding to the second pixels P₂, as shown in FIG. 4. The processor 13 also calculates, in a first mode, a differential image between the infrared subframe F_(inf—B) of the bright image frame and the infrared subframe F_(inf—D) of the dark image frame to separate at least one foreground image, or separates, in a second mode, at least one foreground image according to the first subframe F_(P1) and the second subframe F_(P2), wherein the first mode is, for example, a normal mode and the second mode is, for example, a strong light mode. More specifically, the first subframe F_(P1) is formed by gray level data outputted by the first pixels P₁, the second subframe F_(P2) is formed by gray level data outputted by the second pixels P₂, and the infrared subframe F_(inf) is formed by gray level data outputted by the infrared pixels P_(inf).

When the pixel matrix 111 includes the arrangement of four pixel types, the processor 13 is further configured to form a third subframe F_(P3) according to third image regions I_(P3) in the bright image frame and the dark image frame corresponding to the third pixels P₃ and form a fourth subframe F_(P4) according to fourth image regions I_(P4) in the bright image frame and the dark image frame corresponding to the fourth pixels P₄, as shown in FIG. 4. More specifically, the third subframe F_(P3) is formed by gray level data outputted by the third pixels P₃, and the fourth subframe F_(P4) is formed by gray level data outputted by the fourth pixels P₄.

Referring to FIG. 1 again, the processor 13 includes a light control module 131, a selection module 133, a differential module 135, an offset calculation module 137 and an application module 136, wherein the light control module 131, the selection module 133, the differential module 135, the offset calculation module 137 and the application module 136 are implemented by software and/or hardware without particular limitations. For illustration purposes, the light control module 131, the selection module 133, the differential module 135, the offset calculation module 137 and the application module 136 are shown to be separated from each other herein, but operations thereof are considered to be accomplished by the processor 13. The processor 13 preferably further includes a storage element 130 configured to previously store parameters required during operation, e.g., a predetermined offset range corresponding to an operable range.

The light control module 131 is configured to control the infrared light source 15 to turn on or turn off corresponding to the image capturing of the image sensor 11 such that the image sensor 11 captures and outputs a bright image frame corresponding to the turning-on of the infrared light source 15, and captures and outputs a dark image frame corresponding to the turning-off of the infrared light source 15.

The selection module 133 of the processor 13 is configured to select an operation mode according to the image frame F outputted by the image sensor 11. In one embodiment, the selection module 133 of the processor 13 selects the first mode or the second mode according to an average brightness of the dark image frame. For example, the selection module 133 of the processor 13 calculates only an average brightness of the infrared image regions I_(inf) of the dark image frame or calculates an average brightness of the whole dark image frame, and compares the average brightness with a brightness threshold (e.g., stored in the storage element 130). When the average brightness is smaller than the brightness threshold, it means that the ambient light La is not too strong and thus the first mode is entered. Accordingly, the first mode is referred to a normal mode or a weak light mode herein. When the average brightness is larger than the brightness threshold, it means that the ambient light La is strong and thus the second mode is entered. Accordingly, the second mode is referred to a strong light mode herein.

As mentioned above, when the ambient light La is too strong, the brightness difference between the bright image frame and the dark image frame is not obvious. Accordingly, in another embodiment, the selection module 133 of the processor 13 selects the first mode or the second mode according to an average brightness difference between the bright image frame and the dark image frame. When the average brightness difference is larger than a brightness difference threshold (e.g., stored in the storage element 130), it means that the ambient light La is not too strong and thus the first mode is entered. When the average brightness difference is smaller than the brightness difference threshold, it means that the ambient light La is strong and thus the second mode is entered.

Referring to FIG. 5, it is an operating method of a first mode of the present disclosure. In the first mode, the differential module 135 of the processor 13 calculates a difference between the infrared subframe F_(inf—B) of the bright image frame outputted by the image sensor 11 and the infrared subframe F_(inf D) of the dark image frame outputted by the image sensor 11. For example, it is assumed that the infrared subframe F_(inf—B) includes an object image I₉ and a background image Ia, whereas the infrared subframe F_(inf—D) includes only a background image Ia. When the infrared subframe F_(inf—D) is subtracted from the infrared subframe F_(inf—B), a differential image (F_(inf—B)-F_(inf—D)) only contains the object image I₉ thereby removing the interference from the background image.

Referring to FIGS. 1 and 4, the operation of the second mode is illustrated hereinafter. In this embodiment, a dot object 9 located at a light incident side of the condenser lens 10 is taken as an example for illustration purposes. The image sensor 11 captures, based on a predetermined focal length, and outputs an image frame F (e.g., a bright image frame or a dark image frame) to the processor 13. It is assumed that the selection module 133 selects to enter the second mode, and the offset calculation module 137 of the processor 13 divides the image frame F into a first subframe F_(P1) and a second subframe F_(P2), wherein the first subframe F_(P1) is associated with the first pixels P₁ and the second subframe F_(P2) is associated with the second pixels P₂. As mentioned above, when the object 9 is at the second focal length (i.e. the predetermined focal length) of the condenser lens 10, image regions associated with the object 9 in the first subframe F_(P1) and the second subframe F_(P2) are substantially at corresponding positions without having an offset. When the object 9 is not at the second focal length of the condenser lens 10, image regions associated with the object 9 in the first subframe F_(P1) and the second subframe F_(P2) have an offset therebetween and are not at corresponding positions. The offset calculation module 137 of the processor 13 separates at least one foreground image according to the first subframe F_(P1) and the second subframe F_(P2) of the bright image frame or the dark image frame. As mentioned above, when the ambient light La is strong enough, the brightness difference between the bright image frame and the dark image frame is not obvious, and thus a foreground image is separable according to each of the bright image frame and the dark image frame.

For example, FIG. 4 shows that a first image region I₉₁ in the first subframe F_(P1) shifts upward by S₁ from a center line (e.g., dashed line), and a second image region I₉₂ in the second subframe F_(P2) shifts downward by S₂ from a center line (e.g., dashed line). The offset calculation module 137 of the processor 13 then calculates a first offset between S₁ and S₂, e.g., (S₁-S₂). It should be mentioned that the calculation of the offset is not limited to take the center line as a reference line, and the center line is taken herein only for illustration purposes. It is also possible to implement the calculation of the offset by the block matching or motion detection without particular limitations as long as the first offset between corresponded image regions (e.g., I₉₁ and I₉₂) in the first subframe F_(P1) and the second subframe F_(P2) is obtainable, wherein whether two image regions are corresponded to each other is identified according to, for example, the brightness or shape of the two image regions. The offset calculation module 137 of the processor 13 identifies at least one image region corresponding to the first offset within a predetermined range as at least one foreground image, and identifies the image region outside the predetermined range as the background image.

When the pixel matrix 111 includes the arrangement of four pixel types, the offset calculation module 137 of the processor 13 further divides the image frame F into a third subframe F_(P3) and a fourth image frame F_(P4), wherein the third frame F_(P3) is associated with the third pixels P₃ and the fourth subframe F_(P4) is associated with the fourth pixels P₄. In the second mode, the offset calculation module 137 of the processor 13 separates at least one foreground image according to the third subframe F_(P3) and the fourth subframe F_(P4) of the bright image frame or the dark image frame.

For example, FIG. 4 shows that a third image region I₉₃ in the third subframe F_(P3) shifts rightward by S₃ from a center line (e.g., dashed line), and a fourth image region I₉₄ in the fourth subframe F_(P4) shifts leftward by S₄ from a center line (e.g., dashed line). The offset calculation module 137 of the processor 13 then calculates a second offset between S₃ and S₄, e.g., (S₃-S₄). As mentioned above, the calculation of the offset is not limited to use the subtraction. The offset calculation module 137 of the processor 13 identifies at least one image region corresponding to the second offset within a predetermined range as at least one foreground image, and identifies the image region outside the predetermined range as the background image.

As mentioned above, the predetermined range is previously stored in the storage element 130, and is an offset corresponding to an operable range of the imaging device 1. In other words, when the first offset and/or the second offset exceeds the predetermined range, it means that the image region belongs to the background image.

It should be mentioned that although FIG. 4 shows that the first image region I₉₁ shifts upward by S₁, the second image region I₉₂ shifts downward by S₂, the third image region I₉₃ shifts rightward by S₃ and the fourth image region I₉₄ shifts leftward by S₄, it is only intended to illustrate but not to limit the present disclosure. The shift direction of the image region corresponding to the object 9 is determined according to whether the object 9 is close to or away from the condenser lens 10 from the second focal length as well as the cover pattern of the opaque layer 113 upon the first pixels P₁ to the fourth pixels P₄, and is not limited to that shown in FIG. 4.

The application module 139 outputs a control signal Sc according to at least one foreground image bring identified, e.g., outputting the control signal Sc according to a moving direction, speed and a variation of number of the least one foreground image to control the operation of an application program.

It should be mentioned that, in this embodiment the image region is illustrated with a circle (i.e. corresponding to the dot object 9), but the present disclosure is not limited thereto. The image region may be any part in the image frame F, e.g., edges, capable of clearly showing the offset without particular limitations.

In addition, in order to improve the identification accuracy, the processor 13 further calibrates brightness of the first subframe F_(P1) and the second subframe F_(P2) to be substantially identical using a shading technique. Accordingly, it is able to correctly identify the corresponded image regions (e.g., image regions having identical brightness) in the first subframe F_(P1) and the second subframe F_(P2), e.g., I₉₁ and I₉₂. When the pixel matrix 111 includes the arrangement of four pixel types, the processor 13 further calibrates brightness of the third subframe F_(P3) and the fourth subframe F_(P4) to be substantially identical using the shading technique. Accordingly, it is able to correctly identify the corresponded image regions (e.g., image regions having identical brightness) in the third subframe F_(P3) and the fourth subframe F_(P4), e.g., I₉₃ and I₉₄.

Referring to FIGS. 1, 2A-2B and 4-6, FIG. 6 is a flow chart of an operating method of an imaging device according to one embodiment of the present disclosure. The operating method is, for example, applicable to the imaging device 1 of FIG. 1. As mentioned above, the imaging device 1 includes an infrared light source 15, a plurality of infrared pixels P_(inf), a plurality of first pixels P₁, a plurality of second pixels P₂ and a plurality of microlenses 115. The first pixels P₁ and the second pixels P₂ respectively receive incident light of different phases through a first part and a second part of the microlenses 115. For example, FIG. 1 shows that the first part is at a lower part of the pixel and the second part is at an upper part of the pixel, but the position and ratio with respect to the pixel of the first and second parts are not limited to those shown in FIG. 1.

The operating method of this embodiment includes the steps of: outputting, by an imaging device, a bright image frame when an infrared light source is turned on and a dark image frame when the infrared light source is turned off (Step S61); respectively forming an infrared subframe, a first subframe and a second subframe according to infrared image regions corresponding to infrared pixels, according to first image regions corresponding to first pixels and according to second image regions corresponding to second pixels (Step S62); selecting a first mode or a second mode (Step S63); calculating, in the first mode, a differential image between the infrared subframe of the bright image frame and the infrared subframe of the dark image frame to separate at least one foreground image (Step S64); and separating, in the second mode, at least one foreground image according to the first subframe and the second subframe (Step S65).

Step S61: The light control module 131 of the processor 13 controls the infrared light source 15 to turn on and turn off corresponding to the image capturing of the image sensor 11 such that the image sensor 11 outputs a bright image frame corresponding to the turning-on of the infrared light source 15 and outputs a dark image frame corresponding to the turning-off of the infrared light source 15. More specifically, a frame rate of the image sensor 11 is at least twice of a lighting frequency of the infrared light source 15, e.g., two times, four times and so on.

Step S62: The image sensor 11 outputs every image frame F being captured (e.g., the bright image frame and the dark image frame) to the processor 11 for the post-processing. For example, the processor 11 forms an infrared subframe F_(inf) according to infrared image regions I_(inf) in every image frame F corresponding to the infrared pixels P_(inf), forms a first subframe F_(P1) according to first image regions I_(P1) in every image frame F corresponding to the first pixels P₁, and forms a second subframe F_(P2) according to second image regions I_(P2) in every image frame F corresponding to the second pixels P₂, as shown in FIG. 4. The method of forming the subframe is to recombine pixels according to their original positions in the image frame F so as to form the infrared subframe F_(inf), the first subframe F_(P1) and the second subframe F_(P2).

In some embodiment, the imaging device 1 further includes a plurality of third pixels P₃ and a plurality of fourth pixels P₄ respectively receive incident light of different phases through a third part and a fourth part of the microlenses 115. For example, FIG. 1 shows that the third part is at the right side of the pixel and the fourth part is at the left part of the pixel, but the position and ratio with respect to the pixel of the third part and fourth parts are not limited to those shown in FIG. 1. In the embodiment shown in FIG. 1, the first part and the second part are at two opposite sides along a first axis (e.g., X axis) of the microlenses 115, and the third part and the fourth part are at two opposite sides along a second axis (e.g. Y axis) of the microlenses 115.

When the pixel matrix 111 includes the arrangement of four pixel types, in the Step S62 the processor 11 further forms a third subframe F_(P3) according to third image regions I_(P3) in every image frame F corresponding to the third pixels P₃, and forms a fourth subframe F_(P4) according to fourth image regions I_(P4) in every image frame F corresponding to the fourth pixels P₄. In some embodiments, in the first mode the differential module 135 of the processor 13 generates the infrared subframe F_(inf) without generating the first subframe F_(P1) to the fourth subframe F_(P4); and in the second mode, the offset calculation module 137 of the processor 13 generates the first subframe F_(P1) to the fourth subframe F_(P4) without generating the infrared subframe F_(inf).

Step S63: The selection module 133 of the processor 13 identifies whether ambient light is too strong according to average brightness of the image frame F. In one embodiment, the selection module 133 of the processor 13 selects a first mode or a second mode according to an average brightness value of the dark image frame. In another embodiment, the selection module 133 of the processor 13 selects a first mode or a second mode according to an average brightness difference between the bright image frame and the dark image frame. In the present disclosure, the first mode is, for example, a normal mode or a weak light mode, and the second mode is, for example, a strong light mode. Accordingly, the processor 13 is able to select a proper algorithm according to the intensity of ambient light so as to separate at least one foreground image.

Step S64: When the ambient light is not too strong, a first mode is entered. In this case, the differential module 135 of the processor 13 directly calculates a differential image between the infrared subframe F_(inf—B) of the bright image frame and the infrared subframe F_(inf—D) of the dark image frame to separate at least one foreground image I₉ as shown in FIG. 5. More specifically, gray values outputted by the infrared pixels P_(inf) are calculated in the normal mode without being calculated in the strong light mode.

Step S65: When the ambient light is strong, the second mode is entered. In this case, the offset calculation module 137 of the processor 13 calculates at least one first offset (e.g., S₁ and S₂ shown in FIG. 4) according to the first subframe F_(P1) and the second subframe F_(P2), and identifies at least one image region corresponding to the first offset within a predetermined range as at least one foreground image. As mentioned above, the predetermined range is a predetermined offset range corresponding to an operable range.

When the matrix pixel 111 includes the arrangement of four pixel types, in the Step S65, the offset calculation module 137 of the processor 13 further calculates at least one second offset (e.g., S₃ and S₄ shown in FIG. 4) according to the third subframe F_(P3) and the fourth subframe F_(P4), and identifies at least one image region corresponding to the second offset within a predetermined range as at least one foreground image. It should be mentioned that the foreground images identified according to the first offset and the second offset are not necessary to be identical, and the identified foreground images may partially identical or totally different according to image features in the image frame F.

Finally, the application module 139 of the processor 13 outputs a control signal Sc according to the identified foreground image to perform different applications, e.g., performing the gesture recognition.

In addition, in order to improve the identification accuracy, the processor 13 calibrates brightness of the first subframe F_(P1) and the second subframe F_(P2) to be substantially identical using a shading technique, and calibrates brightness of the third subframe F_(P3) and the fourth subframe F_(P4) to be substantially identical using the shading technique such that, during calculating the offset, corresponded image regions in the first subframe F_(P1) and the second subframe F_(P2) are easier to be found, and corresponded image regions in the third subframe F_(P3) and the fourth subframe F_(P4) are easier to be found.

As mentioned above, the conventional gesture recognition system may not operate accurately under strong ambient light. Therefore, the present disclosure provides an imaging device (e.g., FIG. 1) and an operating method thereof (e.g., FIG. 6) that separate the foreground image using different algorithms under different ambient light intensity so as to overcome the problems of the conventional gesture recognition system.

Although the disclosure has been explained in relation to its preferred embodiment, it is not used to limit the disclosure. It is to be understood that many other possible modifications and variations can be made by those skilled in the art without departing from the spirit and scope of the disclosure as hereinafter claimed. 

What is claimed is:
 1. An imaging device comprising: a condenser lens; an image sensor configured to sense light penetrating the condenser lens, the image sensor comprising: a pixel matrix comprising a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels arranged in a first direction and a second direction; an opaque layer covering upon a first region of the first pixels and upon a second region of the second pixels, wherein the first region and the second region are mirror-symmetrically arranged in the first direction; a plurality of microlenses; and an infrared filter layer covering upon the infrared pixels.
 2. The imaging device as claimed in claim 1, wherein the pixel matrix further comprises a plurality of third pixels and a plurality of fourth pixels, the opaque layer further covers upon a third region of the third pixels and upon a fourth region of the fourth pixels, and the third region and the fourth region are mirror-symmetrically arranged in the second direction.
 3. The imaging device as claimed in claim 2, wherein the first region, the second region, the third region and the fourth region are 5% to 95% of an area of a single pixel.
 4. An imaging device comprising: an infrared light source; a condenser lens; an image sensor configured to sense light penetrating the condenser lens, output a bright image frame when the infrared light source is turned on, and output a dark image frame when the infrared light source is turned off, the image sensor comprising: a pixel matrix comprising a plurality of infrared pixels, a plurality of first pixels and a plurality of second pixels arranged in a first direction and a second direction; an opaque layer covering upon a first region of the first pixels and upon a second region of the second pixels, wherein the first region and the second region are mirror-symmetrically arranged in the first direction; a plurality of microlenses disposed upon the pixel matrix; and an infrared filter layer covering upon the infrared pixels; and a processor configured to form an infrared subframe according to infrared image regions in the bright image frame and the dark image frame corresponding to the infrared pixels, form a first subframe according to first image regions in the bright image frame and the dark image frame corresponding to the first pixels, form a second subframe according to second image regions in the bright image frame and the dark image frame corresponding to the second pixels, and calculate, in a first mode, a differential image between the infrared subframe of the bright image frame and the infrared subframe of the dark image frame to separate at least one foreground image, or separate at least one foreground image according to the first subframe and the second subframe in a second mode.
 5. The imaging device as claimed in claim 4, wherein the processor is configured to select the first mode or the second mode according to an average brightness of the dark image frame.
 6. The imaging device as claimed in claim 4, wherein the processor is configured to select the first mode or the second mode according to an average brightness difference between the bright image frame and the dark image frame.
 7. The imaging device as claimed in claim 4, wherein the processor is configured to separate the at least one foreground image according to the first subframe and the second subframe of the bright image frame or the dark image frame.
 8. The imaging device as claimed in claim 7, wherein the processor is configured to calculate at least one first offset according to the first subframe and the second subframe, and identify an image region corresponding to the first offset within a predetermined range as the at least one foreground image.
 9. The imaging device as claimed in claim 4, wherein the pixel matrix further comprises a plurality of third pixels and a plurality of fourth pixels, the opaque layer further covers upon a third region of the third pixels and upon a fourth region of the fourth pixels, and the third region and the fourth region are mirror-symmetrically arranged in the second direction.
 10. The imaging device as claimed in claim 9, wherein the first region, the second region, the third region and the fourth region are 5% to 95% of an area of a single pixel.
 11. The imaging device as claimed in claim 9, wherein the processor is further configured to form a third subframe according to third image regions in the bright image frame and the dark image frame corresponding to the third pixels, form a fourth subframe according to fourth image regions in the bright image frame and the dark image frame corresponding to the fourth pixels, and separate, in a second mode, the at least one foreground image according to the third subframe and the fourth subframe of the bright image frame or the dark image frame.
 12. The imaging device as claimed in claim 11, wherein the processor is further configured to calculate at least one second offset according to the third subframe and the fourth subframe, and identify an image region corresponding to the second offset within a predetermined range as the at least one foreground image.
 13. The imaging device as claimed in claim 11, wherein the processor is further configured to calibrate brightness of the first subframe and the second subframe to be identical using a shading technique, and calibrate brightness of the third subframe and the fourth subframe to be identical using the shading technique.
 14. An operating method of an imaging device, the imaging device comprising an infrared light source, a plurality of infrared pixels, a plurality of first pixels, a plurality of second pixels and a plurality of microlenses, the first pixels and the second pixels respectively receiving incident light of different phases through a first part and a second part of the microlenses, the operating method comprising: outputting, by the imaging device, a bright image frame when the infrared light source is turned on and a dark image frame when the infrared light source is turned off; forming an infrared subframe according to infrared image regions corresponding to the infrared pixels, forming a first subframe according to first image regions corresponding to the first pixels, and forming a second subframe according to second image regions corresponding to the second pixels; calculating, in a first mode, a differential image between the infrared subframe of the bright image frame and the infrared subframe of the dark image frame to separate at least one foreground image; and separating, in a second mode, at least one foreground image according to the first subframe and the second subframe.
 15. The operating method as claimed in claim 14, further comprising: selecting the first mode or the second mode according to an average brightness of the dark image frame.
 16. The operating method as claimed in claim 14, further comprising: selecting the first mode or the second mode according to an average brightness difference between the bright image frame and the dark image frame.
 17. The operating method as claimed in claim 14, further comprising: calculating at least one first offset according to the first subframe and the second subframe; and identifying an image region corresponding to the first offset within a predetermined range as the at least one foreground image.
 18. The operating method as claimed in claim 14, wherein the imaging device further comprises a plurality of third pixels and a plurality of fourth pixels, the third pixels and the fourth pixels respectively receive incident light of different phases through a third part and a fourth part of the microlenses, and the first part and the second part are two opposite sides of the microlenses along a first axis, and the third part and the fourth part are two opposite sides of the microlenses along a second axis.
 19. The operating method as claimed in claim 18, further comprising: forming a third subframe according to third image regions corresponding to the third pixels; forming a fourth subframe according to fourth image regions corresponding to the fourth pixels; calculating at least one second offset according to the third subframe and the fourth subframe; and identifying an image region corresponding to the second offset within a predetermined range as the at least one foreground image.
 20. The operating method claimed in claim 19, further comprising: calibrating brightness of the first subframe and the second subframe to be identical using a shading technique, and calibrating brightness of the third subframe and the fourth subframe to be identical using the shading technique. 